{template header}

<div class="container">

<ol class="breadcrumb">
  <li><a href="{SITE_URL}">首页</a></li>
  <li class="active">文章</li>
</ol>

<div class="row">



<div class="col-md-8">

<div class="bbox">
<div class="btitle">最新文章</div>
<div class="bc">
<div class="clist">
<ul>
{loop $arrArticle $key $item}
<li>
{if $item['photo']}
<a href="{tsUrl('article','show',array('id'=>$item[articleid]))}">
<img style="float:left;" src="{php echo tsXimg($item['photo'],'article',180,140,$item['path'],'1')}" />
</a>
{/if}

<div class="title"><a href="{tsUrl('article','show',array('id'=>$item[articleid]))}">{$item[title]}</a></div>

<div class="info"><a href="{tsUrl('user','space',array('id'=>$item[user][userid]))}">{$item[user][username]}</a> 发表于 {$item[addtime]}</div>

<div class="content">{$item[content]} (<a href="{tsUrl('article','show',array('id'=>$item[articleid]))}">查看全文</a>)</div>

<div class="cate tar">来自：<a href="{tsUrl('article','cate',array('id'=>$item['cate']['cateid']))}">{$item['cate']['catename']}</a>  ({$item['count_recommend']})推荐  ({$item['count_comment']})评论</div>
<div class="clear"></div>
</li>
{/loop}
</ul>
</div>

<div class="page">{$pageUrl}</div>
</div>
</div>


</div>



<div class="col-md-4">

<a class="btn btn-info btn-block btn-lg" href="{tsUrl('article','add')}">
<span class="glyphicon glyphicon-plus-sign"></span> 写文章</a>
<p></p>


<div class="bbox">
<div class="btitle">文章分类</div>

<div class="bc">

<ul class="nav nav-pills nav-stacked" role="tablist">
{loop $arrCate $key $item}
<li role="presentation" {if $ac=='cate' && $cateid==$item['cateid']}class="active"{/if}><a href="{tsUrl('article','cate',array('id'=>$item['cateid']))}">{$item['catename']}</a></li>
{/loop}
<li role="presentation" {if $ac=='tags'}class="active"{/if}><a href="{tsUrl('article','tags')}">标签</a></li>

</ul>

</div>

</div>


<div class="bbox">
<div class="btitle">推荐阅读</div>
<div class="bc">
<div class="commlist">
<ul>
{loop $arrRecommend $key $item}
<li><a href="{tsUrl('article','show',array('id'=>$item['articleid']))}">{$item['title']}</a></li>
{/loop}
</ul>
</div>
</div>
</div>

<div class="bbox">
<div class="btitle">一周热门</div>
<div class="bc">
<div class="commlist">
<ul>
{loop $arrHot7 $key $item}
<li><a href="{tsUrl('article','show',array('id'=>$item['articleid']))}">{$item['title']}</a></li>
{/loop}
</ul>
</div>
</div>
</div>

<div class="bbox">
<div class="btitle">一月热门</div>
<div class="bc">
<div class="commlist">
<ul>
{loop $arrHot30 $key $item}
<li><a href="{tsUrl('article','show',array('id'=>$item['articleid']))}">{$item['title']}</a></li>
{/loop}
</ul>
</div>
</div>
</div>


<!--广告位-->
{php doAction('gobad','300')}


</div>





</div>
</div>

{template footer}